Trigger Reference
Table of contents
Introduction
G.U.I.D.E ships with a selection of triggers for many use cases. This is a list of all built-in triggers and their configuration settings.
Chorded Action
This trigger is intended to be used in combination with other triggers. It works differently from other triggers as it will only allow the action to be triggered, if the chorded action is currently triggering. This is most often used to bind the same input to multiple different actions. For example the D-pad on a controller can do different things depending on whether the left trigger is held or not. In this case the chorded action would be holding the left trigger down. If multiple chorded action triggers exist, all of them must be triggering for the action to trigger. The chorded action trigger has the following settings:
Setting | Description |
---|---|
Chorded action | The action that needs to be triggered for this action to be triggered. |
Actuation Threshold | This setting has no effect for the chorded action trigger. |
Combo
This trigger allows you to define a sequence of inputs that need to be triggered in order for the action to trigger. This is most often used in fighting games but can also be used to simulate other complex input sequences for example to trigger a magic spell. For the combo trigger you specify a list of actions that need to trigger in the given order. Each action can have a time window in which it needs to be triggered. If the time window is exceeded the combo will reset. Same happens if actions are entered out of order. In addition you can specify a list of cancel actions that will reset the combo if triggered. The combo trigger has the following settings:
Setting | Description |
---|---|
Enable Debug Print | If enabled, the trigger will print debug information about the current state of the combo to the console. |
Steps | A list of actions that need to be triggered in order for the combo to trigger. For each action a time frame can be specified in which the action must be completed for the combo to succeed. |
Cancel Actions | A list of actions that will cancel the combo immediately if triggered. |
Actuation Threshold | This setting has no effect for the combo trigger. |
Down
This is the most basic trigger. It triggers when the input is pressed down or any axis is non-zero. If you don’t specify a trigger for an action then a down trigger with an actuation threshold of 0.0 will be used. The down trigger has the following settings:
Setting | Description |
---|---|
Actuation Threshold | The threshold at which the trigger will activate. If the input value is above this threshold the trigger will activate. |
Hold
This trigger triggers when input is held down for a certain amount of time. An input is considered being held down if the input value is above the actuation threshold. The hold trigger has the following settings:
Setting | Description |
---|---|
Hold Threshold | The time in seconds the input needs to be held down for the trigger to activate. |
Is One Shot | If enabled, the trigger will only trigger once when the Hold Treshold is exceeded and will then need to be released before it can trigger again. If disabled, the trigger will continue to trigger the action every frame after the Hold Threshold is exceeded and while it is still held. |
Actuation Threshold | The threshold at which the trigger will activate. If the input value is above this threshold the trigger will activate. |
Pressed
This trigger triggers once when the input is pressed down. It will not trigger again until the input is released. This is the equivalent of Godot’s Input.is_action_just_pressed
function. The pressed trigger has the following settings:
Setting | Description |
---|---|
Actuation Threshold | The threshold at which the trigger will activate. If the input value is above this threshold the trigger will activate. |
Pulse
This trigger triggers once when the input is pressed and will continue to trigger in configurable intervals as long as the input is held down. This can be used to simulate the OS key repeat functionality for any input. The pulse trigger has the following settings:
Setting | Description |
---|---|
Trigger On Start | If enabled, the trigger will trigger immediately when the input is pressed, otherwise it will wait for the first interval to elapse. |
Initial Delay | The initial delay after the initial actuation before pulsing begins. |
Pulse Interval | The interval in seconds at which the trigger will pulse after the initial delay. |
Max Pulses | The maximum number of pulses that will be triggered. If set to a value <= 0, the trigger will pulse indefinitely. |
Actuation Threshold | The threshold at which the trigger will activate. If the input value is above this threshold the trigger will activate. |
Released
This trigger triggers once when the input is released. This is the opposite of the Pressed trigger and works similar to Godot UI buttons pressed
event (which - contrary to its name - is fired when the button is released). This trigger has the following settings:
Setting | Description |
---|---|
Actuation Threshold | The threshold at which the trigger will consider the input as actuated. |
Stability
This trigger triggers depending on whether the input changes after being actuated. This is mostly useful for touch input to distinguish screen taps from screen drags. The trigger has the following settings:
Setting | Description |
---|---|
Trigger When | There are two modes available. When set to Input Is Stable will trigger while the input remains unchanged while still being actuated. This can be used to detect a screen tap where the finger should not move while being on the screen. The second mode is Input Changes. This will trigger when the input is actuated and then changes its value while remaining actuated. This can be used to detect a screen drag or flick. |
Max Deviation | If the length of the input vector changes by more than this value, the input is considered “changed”. |
Tap
This trigger triggers when the input is pressed and released within a certain time frame. Can be used with hold trigger to bind two different actions to the same input (tap for one action, hold for another). The tap trigger has the following settings:
Setting | Description |
---|---|
Tap Threshold | The time that the player has to release the input after actuating it. If this time is exceeded, the input is not considered to be a tap. |
Actuation Threshold | The threshold at which the trigger will activate. If the input value is above this threshold the trigger will activate. |